home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Skunkware 5
/
Skunkware 5.iso
/
src
/
X11
/
tclMotif-1.4
/
wtour
/
popup1.tcl
< prev
next >
Wrap
Text File
|
1995-06-29
|
494b
|
21 lines
#
# a popup menu
#
# create label with popup on <Btn3Down>
xmLabel .label managed \
-labelString "ctrl-p or Btn3Down popups from me"
.label setValues -translations \
"<Btn3Down>: action(popIt %event)"
# create the actual menu
xmPopupMenu .label.menu -menuAccelerator "Ctrl <Key> p"
xmPushButton .label.menu.btn1 managed
xmPushButton .label.menu.btn2 managed
# popups the menu when requested
proc popIt {event} {
.label.menu menuPosition $event
.label.menu manageChild
}